const path = require('path');

function resolve(dir) {
    return path.join(__dirname, dir);
}

module.exports = {
    publicPath: './',
    outputDir: 'dist',
    assetsDir: 'static',
    filenameHashing: true,
    lintOnSave: false,
    devServer: {
        hot: true,
        port: 8081,
        disableHostCheck: true,
    },
    // 自定义webpack配置
    configureWebpack: {
        // plugins: [
        //     // new BundleAnalyzerPlugin(),
        // ],
        resolve: {
            alias: {
                '@': resolve('src'),
            },
        },
    },
};
